﻿using System;
using System.Collections;
using System.Collections.Generic;

namespace InfoGenerateSystem.Persistence.IDao
{
    public interface IGenericDao
    {
        void Delete(string statementName, object obj);
        object Find(string statementName, object keyValue);
        string GetConnectionString();
        string GetSQL(string statementName, object parameterObject);
        object Insert(string statementName, object obj);
        IList<T> Query<T>(string statementName, object parameterObject);
        System.Collections.IList Query(string statementName, object parameterObject);
        System.Data.DataSet Query(string statementName, object parameterObject, int pageSize, int pageIndex, string indexCol, string order, int total);
        IList<Hashtable> QueryForPagedList(string statementName, object parameterObject,
            int pageSize, int pageIndex, string indexCol, string order, int total);
        int QueryCount(string statementName, object parameterObject);
        System.Data.DataSet QueryForTable(string statementName, object parameterObject);
        void Update(string statementName, object obj);

        
        IList<Hashtable> QueryHashtableListBySql(string sql);
        System.Data.DataSet QueryForPagedDataset(string sql,
            int pageSize, int pageIndex, string indexCol, string order, int total);
        int QueryForRecordCount(string sql);
        System.Data.DataSet QueryTableBySql(string sql);
    }
}
